package com.faxsun.web.security;

import javax.servlet.http.HttpSessionEvent;
import javax.servlet.http.HttpSessionListener;

import mblog.web.interceptor.bean.NavDataMap;

/**
 * 在Session销毁时，移除Map中的对应内容
 * 
 * @author songdragon
 *
 */
public class WebHttpSessionListener implements HttpSessionListener {

	@Override
	public void sessionCreated(HttpSessionEvent hse) {
		// Do Nothing

	}

	@Override
	public void sessionDestroyed(HttpSessionEvent hse) {

		String sessionid = hse.getSession().getId();
		NavDataMap.navDatas.remove(sessionid);
	}

}
